<template>
    <view style="width: 100%; height:500rpx;padding: 0 20rpx;">
        <lechart ref="chart"></lechart>
    </view>
</template>
<script>
const echarts = require('../static/echarts.min.js')
//---or----------------------------------
import lechart from '../uni_modules/lime-echart/components/l-echart/l-echart.vue'
export default {
    components: {
        lechart
    },
    data() {
        return {
            option:{
                xAxis: {
                    type: 'category',
                    data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun']
                },
                yAxis: {
                    type: 'value'
                },
                series: [
                    {
                    data: [120, 200, 150, 80, 70, 110, 130],
                    type: 'bar'
                    }
                ]
             }
        }
    },
    mounted() {
        console.log('进来了');

        this.$refs.chart.init(echarts, chart => {
			chart.setOption(this.option);
            console.log(11);
            
		});
    }
}
</script>
<style lang="scss" scoped></style>